<div class="role-type">

  <nz-collapseset>
    <nz-collapse [nzTitle]="panels.name" [nzActive]="panels.active" [nzDisabled]="panels.disabled">
      <form nz-form [nzLayout]="'inline'" >
        <div nz-form-item nz-col [nzSpan]="6">
          <div nz-form-label nz-col [nzSm]="9" [nzXs]="6">
            <label>角色类型名称</label>
          </div>
          <div nz-form-control>
            <nz-input  [(ngModel)]="roleTypeBean.roleTypeName" name="roleTypeName">
            </nz-input>
          </div>
        </div>
        <button nz-button [nzSize]="'large'" [nzType]="'primary'" (click)="query()">查询</button>
      </form>

    </nz-collapse>
  </nz-collapseset>
  <ul nz-menu [nzMode]="'horizontal'">
    <li  permission="SID00004" nz-menu-item (click)="add(title, content, footer)"><i class="anticon anticon-plus"></i>添加</li>
    <li permission="SID00005" nz-menu-item (click)="update(title, content, footer)"><i class="anticon anticon-copy"></i>修改</li>
  </ul>
  <nz-table #nzTable [nzDataSource]="list" nzSize="middle" [nzBordered]="true" [nzIsPagination]="false" (nzDataChange)="displayDataChange($event)">
    <thead nz-thead>
    <tr>
      <th nz-th [nzCheckbox]="true">
        <label nz-checkbox [(ngModel)]="allChecked" [nzIndeterminate]="indeterminate" (ngModelChange)="checkAll($event)">
        </label>
      </th>
      <th nz-th><span>角色类型名称</span></th>
      <th nz-th><span>角色类型描述</span></th>
    </tr>
    </thead>
    <tbody nz-tbody>
    <tr nz-tbody-tr *ngFor="let data of list">
      <td nz-td [nzCheckbox]="true">
        <label nz-checkbox [nzDisabled]="data.disabled" [(ngModel)]="data.checked" (ngModelChange)="refreshStatus($event)">
        </label>
      </td>
      <td nz-td>{{data.roleTypeName}}</td>
      <td nz-td>{{data.roleTypeDescribe}}</td>
    </tr>
    </tbody>
  </nz-table>

  <ng-template #title>
    <span>{{modelTitle}}</span>
  </ng-template>
  <ng-template #content>
    <role-type-add-page *ngIf="modal==0" [inValue]="totalList" (outPut)="addOutPut($event)"></role-type-add-page>
    <role-type-update-page *ngIf="modal==1" [inValue]="updateData" (outPut)="addOutPut($event)"></role-type-update-page>
  </ng-template>
  <ng-template #footer>
    <div>

    </div>
  </ng-template>
</div>
